package ch09.home;

class Exercise9_12 {
	public static int getRand(int from, int to) {
		return (int) (Math.random() * (Math.abs(to - from) + 1)) + Math.min(from, to);
	}

	public static void main(String[] args) {
		for (int i = 0; i < 20; i++)
			System.out.print(getRand(1, -3) + " ");
	}
}
/*
-2 0 -3 -2 1 0 0 1 1 -3 1 -2 0 -2 -3 -3 -3 -1 1 -1 
*/